/**
 * 项目名：	Rumba Plan
 * 
 * 版权所有(C)，上海海鼎信息工程股份有限公司，2006，所有权利保留。
 * 
 * 文件名：	CRole.java
 * 模块说明：	
 * 修改历史：
 * 2006-8-20 - lxm - 创建。
 */
package com.hd123.rumba.user;

import com.hd123.rumba.cartridge.FVRumbaSystemCommon;
import com.hd123.rumba.runtime.CBaseEntity;
import com.hd123.rumba.util.HashMap2;

/**
 * 角色 | 常量类
 * 
 * @author lxm
 * @see IRole
 * 
 */
public class CRole extends CBaseEntity {

  public static String CAPTION_CLASS = "角色";
  public static String CAPTION_ROLE = "角色";

  /** 构件包前缀 */
  public static final String FUNCV_PREFIX = FVRumbaSystemCommon.FUNCV_PREFIX;

  /** 状态取值 */
  public static final Integer VALUE_STATE_NORMAL = new Integer(0);
  public static String CAPTION_STATE_NORMAL = "正常";
  public static final Integer VALUE_STATE_DELETED = new Integer(999);
  public static String CAPTION_STATE_DELETED = "已删除";
  public static HashMap2 STATEMAP = new HashMap2().put2(VALUE_STATE_NORMAL, CAPTION_STATE_NORMAL)
      .put2(VALUE_STATE_DELETED, CAPTION_STATE_DELETED);

  /** 角色类型取值 */
  public static final Integer VALUE_ROLETYPE_PRIVATE = new Integer(0);
  public static String CAPTION_ROLETYPE_PRIVATE = "私有角色";
  public static final Integer VALUE_ROLETYPE_PUBLIC = new Integer(1);
  public static String CAPTION_ROLETYPE_PUBLIC = "公共角色";
  public static HashMap2 ROLETYPEMAP = new HashMap2().put2(VALUE_ROLETYPE_PRIVATE,
      CAPTION_ROLETYPE_PRIVATE).put2(VALUE_ROLETYPE_PUBLIC, CAPTION_ROLETYPE_PUBLIC);

  /** @see IRole#getCode() */
  public static String CAPTION_CODE = "代码";
  public static final int LENGTH_CODE = 100;

  /** @see IRole#getName() */
  public static String CAPTION_NAME = "名称";
  public static final int LENGTH_NAME = 100;

  public static String CAPTION_ROLETYPE = "角色类型";

  /** @see IRole#getRemark() */
  public static String CAPTION_REMARK = "备注";
  public static final int LENGTH_REMARK = 200;

  /** 系统默认角色：根域管理员角色之代码 */
  public static final String VALUE_CODE_ROOT_ADMIN = "admin";

  /** 系统默认角色：根域管理员角色之名称 */
  public static final String VALUE_NAME_ROOT_ADMIN = "管理员";

  public static String CAPTION_USERS = "包含的用户";
  public static final String PERMISSION_FA_USERS = FUNCV_PREFIX + ".角色.字段.包含的用户";
}
